<template>

</template>

<script>
export default {
  mounted(){
    window.APP_BRIDGE_UPDATE = (token)=>{
      localStorage.setItem('token',token)
    }
    let {token,uid,type,page} = this.$route.query;
    if(token && uid && type  && page){
      this.$store.commit("SET_UID",uid);
      this.$store.commit("SET_TOKEN",token);
      this.$store.commit("SET_USER",{token,uid,type});
      this.$router.replace({name:page});
    }else{
      this.$router.replace({name:'login'});
    }
  }
}
</script>

<style>

</style>
